package org.will.demo.events.dto;

import org.apache.commons.lang3.StringUtils;

import java.util.List;
import java.util.Map;

/**
 * Created by EdifierWill on 2016/9/1.
 */
public class AddRequest {

    private String type;
    private String id;
    private String search_index;
    private Map<String,String> content;
    private List<String> sort_fields;

    public String getType() {
        if(StringUtils.isBlank(type))
            return "default";
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getSearch_index() {
        return search_index;
    }

    public void setSearch_index(String search_index) {
        this.search_index = search_index;
    }

    public Map<String, String> getContent() {
        return content;
    }

    public void setContent(Map<String, String> content) {
        this.content = content;
    }

    public List<String> getSort_fields() {
        return sort_fields;
    }

    public void setSort_fields(List<String> sort_fields) {
        this.sort_fields = sort_fields;
    }
}
